#include <iostream>
using namespace std;

class A
{
private:
    int val;

public:
    A(int n = 0)
    {
        val = n;
    }

    A(A a)
    {
        val = a.val;
    }
    void printValue() {
        cout << val << endl;
    }
};
int main()
{
    A a = 10;
    A b = a;
    b.printValue();
    return 0;
}